package generator

import "beergo/plugins/maker"

func init() {
	VideoClass()
	VideoClassCategory()
}

func VideoClass() {
	c := maker.CreateTable("VideoClass","视频课程","check")
	c.AddManyToOne("cat","分类","VideoClassCategory")
	c.AddTitle()
	c.AddContent()
	c.AddText("cover","封面").SetLength(300)
	c.AddText("url","视频地址").SetLength(500)
	c.AddCreateAt()
	c.Generate()
}

func VideoClassCategory() {
	c := maker.CreateTable("VideoClassCategory", "视频课程分类","check")
	c.AddName()
	c.AddSort()
	c.Generate()
}
